if(!jsx3.lang.Class.forName("ux.cdb.admin.system.school.builder.step2.BaseInfo")) {
	jsx3.lang.Class.defineClass("ux.cdb.admin.system.school.builder.step2.BaseInfo",
			ux.megatron.gui.WizardPanel,
			null,
			function (block) {
				/**
				 * instance initializer
				 * @param strName {String} unique name distinguishing this object from all other JSX GUI objects in the JSX application
				 * @param vntLeft {int|String} either a number (i.e, 12, 30, etc) or a number and a unit value (i.e., "25%", "36pt", etc); if a number is passed, pixels will be the assumed unit when painted to screen
				 * @param vntTop {int|String} either a number (i.e, 12, 30, etc) or a number and a unit value (i.e., "25%", "36pt", etc); if a number is passed, pixels will be the assumed unit when painted to screen
				 * @param vntWidth {int|String} either a number (i.e, 12, 30, etc) or a number and a unit value (i.e., "25%", "36pt", etc); if a number is passed, pixels will be the assumed unit when painted to screen
				 * @param vntHeight {int|String} either a number (i.e, 12, 30, etc) or a number and a unit value (i.e., "25%", "36pt", etc); if a number is passed, pixels will be the assumed unit when painted to screen
				 * @param strHTML {String} Text/HTML markup to place in the jsx3.gui.Block instance
				 */
				block.prototype.init = function(strName, vntLeft, vntTop, vntWidth, vntHeight, strHTML) {
					//call constructor for super class (the super expects the name of the object and the function that it is an instance of)
					this.jsxsuper(strName, vntLeft, vntTop, vntWidth, vntHeight, strHTML);
				};

				block.prototype.initialize = function(msg) {
				};
				
				block.prototype.initialize = function() {
					this.builder = this.getAncestorOfType("ux.cdb.admin.system.school.builder.Builder");
                    this.wizard = this.getAncestorOfType("ux.megatron.gui.SteppedWizard");
                    this.paneMaster = this.get("blkBaseInfo");
                    if(this.wizard.editMode == 'Modify'){
						if(this.wizard.detailCDF.communication)
							this.paneMaster.setDataByObject(this.wizard.detailCDF.communication);
					}
                };

				block.prototype.onNext = function(objWIZARD, objBUTTON, objEVENT, strCURRENTPANEL) {
					if(this.checkInput()) {
						var _data = this.paneMaster.getData();
/* @JSC :: begin DEBUG */
						jsx3.log("BaseInfo#onNext : current data of step1 : " + this.wizard.cacheCDF.step1);
						jsx3.log("BaseInfo#onNext : current data : " + _data);
/* @JSC :: end */
						//var cdf = jsx3.xml.CDF.Document.newDocument();
						if(this.wizard.cacheCDF.step2) 
							delete this.wizard.cacheCDF.step2;
						/* _data.getFirstChild().setAttribute("provinceCode2","省、自治区、直辖市");
						_data.getFirstChild().setAttribute("regionCode","地区、市");
						_data.getFirstChild().setAttribute("countyCode","县区"); */
                        this.wizard.cacheCDF.step2 = _data;
						//TODO: get and cache current data,used to transaction processing.
                        return null; 
                    } else {
                        return "NONE";
                    }
				};

				block.prototype.onPrev = function(objWIZARD, objBUTTON, objEVENT, strCURRENTPANEL) {
					return null; // return "NONE" to not advance panels
				};

				block.prototype.onRevert = function(objWIZARD, objBUTTON, objEVENT, strCURRENTPANEL) {
					return null; // return "NONE" to not last status
				};

				block.prototype.onCancel = function(objWIZARD, objBUTTON, objEVENT, strCURRENTPANEL) {
                    this.builder.onClose();
					return null; // return "NONE" to not advance panels
				};

				block.prototype.onFinish = function(objWIZARD, objBUTTON, objEVENT, strCURRENTPANEL){
					if(this.checkInput()) {
						var _data = this.paneMaster.getData();
						if(this.wizard.cacheCDF.step2) 
							delete this.wizard.cacheCDF.step2;
						this.wizard.cacheCDF.step2 = _data;
						this.builder.doSave();
                    } else {
                        return "NONE";
                    }
				};
				
				block.prototype.onCustomNav = function(objWIZARD, objBUTTON, objEVENT, strCURRENTPANEL) {
					return null; // return "NONE" to not advance panels
				};

				block.prototype.onBeforeShow = function(objWIZARD, objBUTTON, objEVENT, strLASTPANEL) {
					if(!this.getChild(0)) {
						var me = this;
						ux.megatron.Main.loadUIResourceAsync(me, "ux.cdb.admin","ux/cdb/admin/system/school/builder/step2/ui/baseInfoContent.xml", me, me.initialize);
					}
					return null; // return "NONE" to not advance panels
				};

				block.prototype.onAfterHide = function(objWIZARD, objBUTTON, objEVENT, strNEXTPANEL) {
					return null; // return "NONE" to not advance panels
				};
				
				block.prototype.checkInput = function() {
/* @JSC :: begin DEBUG */
					jsx3.log("BaseInfo#checkInput");
/* @JSC :: end */
					var errorMsgs = this.paneMaster.doValidate();
                    this._message = errorMsgs === null ? null : (errorMsgs[0].label ? errorMsgs[0].label + " : " +errorMsgs[0].message : errorMsgs[0].message);
                    if(this._message == null) {
/* @JSC :: begin DEBUG */
						jsx3.log("BaseInfo#checkInput success!");
/* @JSC :: end */
                        this.wizard.getMessageLabel().setText("&nbsp;");
                        return true;
                    } else {
/* @JSC :: begin DEBUG */
						jsx3.log("BaseInfo#checkInput failed!");
/* @JSC :: end */
                        var tip = ux.megatron.Main.getServer().getDynamicProperty("@cdb@system@schoolBuilder@schoolInfoValidaeMSG");
                        this.wizard.getMessageLabel().setText(this._message ? this._message : tip);
						//jsx3.log("BaseInfo#checkInput failed! tip : " + tip + " messageLabel : " + this.wizard.getMessageLabel());
                        return false;
                    }
                };
			}
	);
}
